package lab02.test04;
//定义员工类，姓名，
public class Employee {
  private  String name;
  private  String number;
  private float salary;

//构造无参函数
    public Employee(String name, String number, double salary) {
    }
    //构造有参函数
    public Employee(String name,String number,float salary){
          this.name = name;
          this.number = number;
          this.salary =salary;
    }
//获取姓名
    public void setName(String name) {
        this.name = name;
    }
    public String getName() {
        return name;
    }
    //获取号码

    public void setNumber(String number) {
        this.number = number;
    }

    public String getNumber() {
        return number;
    }
    //获取基本工资

    public void setSalary(float salary) {
        this.salary = salary;
    }

    public float getSalary() {
        return salary;
    }

    public void print(){
        System.out.println("姓名："+name+" "+"号码："+number +" "+"基本工资："+salary);
    }
}
